---
title: "Accessibility Checker Rule Help: Valerie_Caption_InTable"
---
import "../../../styles/ToolHelp.scss"
import { CodeSnippet, Tag } from "carbon-components-react";

<div className="toolHelp">
<Row>
<Column colLg={16} colMd={8} colSm={4} className="toolHead">

### `<caption>` element is not nested inside a `<table>` element

<div id="locLevel"></div>

`<caption>` element must be nested inside the associated `<table>` element

</Column>
</Row>
<Row>
<Column colLg={11} colMd={5} colSm={4} className="toolMain">

### Why is this important?

The caption for a table is an identifier and acts like a title or heading for the table. The `<caption>` element allows screen readers to navigate directly to the caption to get the description of the table.

<div id="locSnippet"></div>

### What to do

 * Nest the `<caption>` element inside the associated `<table>` element. For example:

<CodeSnippet type="multi" light={true}>&lt;table id="data_table1" border="1" summary="A simple data table showing the number of boys and girls in each grade of an elementary school"&gt;
        &lt;caption&gt;Boys and Girls in Elementary School Classes&lt;/caption&gt;
        &lt;tr&gt; ... &lt;/tr&gt;
        &lt;tr&gt; ... &lt;/tr&gt;
&lt;/table&gt;</CodeSnippet>

</Column>
<Column colLg={5} colMd={3} colSm={4} className="toolLeft">

### About this requirement

[IBM 1.3.1 Info and Relationships](https://www.ibm.com/able/requirements/requirements/#1_3_1)
[WCAG 2.1 technique H39](https://www.w3.org/WAI/WCAG21/Techniques/html/H39)

### Who does this affect?

 * Blind people using screen readers

</Column>
</Row>
</div>

export default ({ children, _frontmatter }) => (<React.Fragment>{children}</React.Fragment>)
